package src.jeu;

public class Disk implements Comparable{

	private int size;
	
	Disk(int size){
		this.size = size;
	}
	
	public int compareTo(Object objet) {//!!!!exception sur le cats
		Disk disk = (Disk)objet;
		if (this.size<disk.size)return -1;
		if (this.size>disk.size)return 1;
		else return 0;
	}
	
	public int getSize(){
		return this.size;
	}
	
	public String toString(){
		return "Disk["+getSize()+"]";
	}
}
